package kassiopeia.plugin.crawler.processor;

import kassiopeia.plugin.crawler.processor.config.Item;

public class Match {
    private int level;
    private Item item;

    public Match(int level, Item item) {
        this.level = level;
        this.item = item;
    }

    public int getLevel() {
        return level;
    }

    public void setLevel(int level) {
        this.level = level;
    }

    public Item getItem() {
        return item;
    }

    public void setItem(Item item) {
        this.item = item;
    }

    @Override
    public String toString() {
        StringBuilder builder = new StringBuilder();
        builder.append("Match:\n");
        builder.append("---------------------------------------\n");
        builder.append("id: ").append(item.getId()).append("\n");
        builder.append("name: ").append(item.getName()).append("\n");
        builder.append("description: ").append(item.getDescription()).append("\n");
        builder.append("level: ").append(level).append("%\n");
        builder.append("---------------------------------------");
        return builder.toString();
    }
}
